package com.edu.boot.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import java.io.Serializable;
import java.util.Date;
import java.util.List;

import lombok.Data;

/**
 * 评论数据表
 * @TableName community_comment
 */
@TableName(value ="community_comment")
@Data
public class CommunityComment implements Serializable {
    /**
     *
     */
    @TableId(type = IdType.AUTO)
    private Integer id;

    /**
     * 评论人
     */
    private Integer uid;
    /**
     * 昵称
     */
    @TableField(exist = false)
    private String nickname;
    //头像
    @TableField(exist = false)
    private String imageData;

    /**
     * 评论内容
     */
    private String remark;

    /**
     * 帖子id
     */
    private Integer communityId;

    /**
     * 创建时间
     */
    private Date createTime;

    /**
     * 父评论id
     */
    private Integer parentId;
    
    /**
     * 评论回复
     */
    @TableField(exist = false)
    private List<CommunityComment> replies;
    
    @TableField(exist = false)
    private static final long serialVersionUID = 1L;
}
